/* settings-layout.css - 布局和导航 */

/* 主体布局 */
.settings-body {
  display: flex;
  flex: 1;
  overflow: hidden;
}

/* 侧边栏 */
.settings-sidebar {
  width: 220px;
  background: linear-gradient(180deg, #f8fafc 0%, #f1f5f9 100%);
  padding: 1.5rem 0;
}

/* 菜单项样式 */
.menu-item {
  display: flex;
  align-items: center;
  width: calc(100% - 1.5rem);
  margin: 0 0.75rem;
  padding: 0.875rem 1.5rem;
  border: none;
  background: transparent;
  cursor: pointer;
  text-align: left;
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1); /* 使用更平滑的缓动函数 */
  font-size: 0.875rem;
  font-weight: 500;
  color: #475569;
  position: relative;
  overflow: hidden;
  border-radius: 8px;
  margin-bottom: 0.25rem;
  will-change: transform, background-color; /* 声明动画属性 */
}

/* 菜单项微光效果 */
.menu-item::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(255, 255, 255, 0.3) 50%,
    transparent 100%
  );
  background-size: 200% 100%;
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
  border-radius: 8px;
}

.menu-item:hover::before {
  opacity: 1;
  animation: shimmer 1.5s ease-in-out infinite;
}

.menu-item:hover {
  background-color: rgba(59, 130, 246, 0.1);
  color: #1e293b;
  transform: translateX(4px); /* 增加位移幅度 */
  /* 发光光晕阴影特效 */
  box-shadow: 
    0 8px 24px rgba(0, 0, 0, 0.12),
    0 0 16px rgba(102, 126, 234, 0.4);
}

.menu-item.active {
  background-color: rgba(59, 130, 246, 0.15);
  color: #3b82f6;
  font-weight: 600;
  box-shadow: 
    0 2px 8px rgba(59, 130, 246, 0.1),
    0 0 16px rgba(102, 126, 234, 0.4);
  transform: translateX(4px);
  transition: all 0.5s cubic-bezier(0.22, 1, 0.36, 1); /* 选中状态使用更慢的动画 */
}

/* 深色模式下的菜单项动画 */
.dark .menu-item {
  color: #cbd5e1;
}

.dark .menu-item:hover {
  background-color: rgba(59, 130, 246, 0.2);
  color: #f1f5f9;
}

.dark .menu-item.active {
  background-color: rgba(59, 130, 246, 0.25);
  color: #60a5fa;
}

.menu-icon {
  margin-right: 0.75rem;
  font-size: 1.125rem;
  width: 20px;
  text-align: center;
}

/* 返回按钮样式 */
.back-btn {
  background: #f1f5f9;
  border: none;
  border-radius: 50%;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
  font-size: 1.25rem;
  color: #64748b;
}

.back-btn:hover {
  background: #ffffff;
  color: #334155;
  /* 发光光晕阴影特效 */
  box-shadow: 
    0 0 12px rgba(59, 130, 246, 0.6);
}